home *** CD-ROM | disk | FTP | other *** search
/ Personal Computer World 2009 February / PCWFEB09.iso / Software / Linux / Kubuntu 8.10 / kubuntu-8.10-desktop-i386.iso / casper / filesystem.squashfs / var / lib / dpkg / info / bzip2.preinst < prev    next >
Text File  |  2008-06-23  |  543b  |  21 lines

  1. #!/bin/sh
  2. set -eu
  3.  
  4. # If and only if we are uprading from a version lower than 0.9.5d-3,
  5. # then we want to break the old /usr/share/doc/libbz2 symlink (which was 
  6. # pointing to libbz2).
  7. if [ "$1" = "upgrade" ] && dpkg --compare-versions "$2" "<<" "0.9.5d-3"
  8. then
  9.     if test -L /usr/share/doc/bzip2
  10.     then
  11.     rm -f /usr/share/doc/bzip2
  12.     fi
  13. fi
  14.  
  15. # And we should never ever have a directory in /usr/doc/bzip2
  16. if [ -d /usr/doc/bzip2 ] && [ ! -L /usr/doc/bzip2 ]
  17. then
  18.     echo "Cleaning up left-over /usr/doc/bzip2."
  19.     rm -fr /usr/doc/bzip2
  20. fi
  21.